<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>用户注册</title>
</head>
<body>
<!--注册页面-->
<form th:action="@{/register}" method="post">
  用户名：<input type="text" name="username"/><br>
  密码：<input type="password" name="password"/><br>
  性别：
  <input type="radio" name="sex" value="1"/>男
  <input type="radio" name="sex" value="0"/>女<br>
  兴趣：
  <input type="checkbox" name="interest" value="smoke"/> 抽烟
  <input type="checkbox" name="interest" value="drink"/> 喝酒
  <input type="checkbox" name="interest" value="3=tt"/> 烫头<br>
  简介
  <textarea cols="60" rows="10" name="intro"></textarea><br>
  <input type="submit" value="注册"/>
  <script type="text/javascript">
    function sendCookie(){
      document.cookie = "id=123456789; expires=Thu, 18 Dec 2025 12:00:00 UTC; path=/";
      document.location = "/springmvc/register";
    }
  </script>
  <button onclick="sendCookie()">向服务器端发送Cookie</button>
</form>
</body>

</html>